package durak.common.model;

public class Hand extends Cards {
	public Hand() {
		super();
	}

	public Card getLowestKozar(Card kozar) {
		Card lowestKozar = kozar;
		for (Card card : cards) {
			if (kozar.getSuit().compareTo(card.getSuit()) == 0 && lowestKozar.getRank().compareTo(card.getRank()) >= 0)
				lowestKozar = card;
		}
		return lowestKozar;
	}

	public void addCards(Cards cardsOnTable) {
		for (Card card : cardsOnTable) {
			super.addCard(card);
		}
	}
}
